Skip to content

Refactor docstrings in optimization_problem.go to remove redundant formatting#33

Merged
kwesiRutledge merged 2 commits intomainfrom
copilot/refactor-docstring-formatting
Feb 18, 2026
Merged

Refactor docstrings in optimization_problem.go to remove redundant formatting#33
kwesiRutledge merged 2 commits intomainfrom
copilot/refactor-docstring-formatting

Conversation

Copy link
Contributor

Copilot AI commented Feb 18, 2026

Docstrings contained redundant method names and "Description:" labels that duplicated information already present in the function signature.

Changes

Transformed 20 docstrings from:

/*
AddVariable
Description:

    This method adds an "unbounded" continuous variable to the model.
*/
func (op *OptimizationProblem) AddVariable() symbolic.Variable

To:

/*
This method adds an "unbounded" continuous variable to the model.
*/
func (op *OptimizationProblem) AddVariable() symbolic.Variable
  • Removed method names from docstring headers
  • Removed "Description:" labels
  • Removed unnecessary leading indentation
  • Preserved "Notes:" and "Note:" sections where present
  • Maintains Go documentation conventions (capital letter start, complete sentences)

Net reduction: 67 lines across 20 methods.


💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.

… and Description labels

Co-authored-by: kwesiRutledge <9002730+kwesiRutledge@users.noreply.github.com>
Copilot AI changed the title [WIP] Refactor comment structure in optimization_problem.go Refactor docstrings in optimization_problem.go to remove redundant formatting Feb 18, 2026
Copilot AI requested a review from kwesiRutledge February 18, 2026 03:18
@kwesiRutledge kwesiRutledge marked this pull request as ready for review February 18, 2026 03:22
@kwesiRutledge kwesiRutledge merged commit 308a871 into main Feb 18, 2026
3 checks passed
@kwesiRutledge kwesiRutledge deleted the copilot/refactor-docstring-formatting branch February 18, 2026 03:23
@codecov
Copy link

codecov bot commented Feb 18, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 85.77%. Comparing base (0214315) to head (1f7eb68).
⚠️ Report is 16 commits behind head on main.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #33      +/-   ##
==========================================
- Coverage   86.76%   85.77%   -0.99%     
==========================================
  Files          27       35       +8     
  Lines        3687     3185     -502     
==========================================
- Hits         3199     2732     -467     
+ Misses        440      396      -44     
- Partials       48       57       +9     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants